package P5.T14;

import javax.swing.*;
import java.awt.*;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;

public class T14 {
    private static JButton btn;
    private static JPanel pnl;
    private static JButton[] btns;
    public static void main(String[] args) {
        Color c=JColorChooser.showDialog(null,"选择一个颜色",Color.GREEN);
        JOptionPane.showMessageDialog(null,c);
//        String password = JOptionPane.showInputDialog("密码","AAA");
//        JOptionPane.showMessageDialog(null,password);

//        int result=JOptionPane.showConfirmDialog(null,"你好啊","信息",JOptionPane.YES_NO_CANCEL_OPTION, JOptionPane.ERROR_MESSAGE);
//        if(result==JOptionPane.YES_OPTION){
//            JOptionPane.showMessageDialog(null,"你点了Yes");
//        }
//        else if(result==JOptionPane.NO_OPTION){
//            JOptionPane.showMessageDialog(null,"你点了No");
//        }
    }
}
